//取表格值
var arr = $this.model['table_1755738741890_IKo2g'];
for(let i = 0; i<arr.length; i++){
    let a = parseFloat (arr[i].body_1755738876240_kVrDg)
    let b = parseFloat (arr[i].body_1755740940736_vNNbE)
    if(b != undefined && b != 0) {
        let r = a-b;
        arr[i].body_1756890726483_ZVNw0 = r
    }else{
        arr[i].body_1755740940736_vNNbE = b;
    }
}
var arr = $this.model['table_1755739234177_VGgw6'];
for(let i = 0; i<arr.length; i++){
    let b = parseFloat (arr[i].body_1756890890163_hsAxa)
    arr[i].body_1755741064871_8zdXz = b;//本次收款金额 = 未收款金额
}

var arr = $this.model['table_1755738741890_IKo2g'];
for(let i = 0; i<arr.length; i++){
    arr[i].body_1756890726483_ZVNw0 = arr[i].body_1755738876240_kVrDg;
}

console.log("收款金额",$this.model.body_1755738876240_kVrDg);
$this.model.body_1756890726483_ZVNw0 = $this.model.body_1755738876240_kVrDg
console.log("未收款金额",$this.model.body_1756890726483_ZVNw0);

var arrt = $this.model
for(let i = 0; i<arr.length; i++){
    arr[i].body_1756890726483_ZVNw0 = arrt[i].body_1755738876240_kVrDg ;
}

//parseFloat解决(除零错误,NaN 或脚本异常);toFixed(2) 限制小数位(浮点数精度,计算结果不精确)
//表体【收款金额】 = 表体【百分比(%)】 * 表头【合同金额】
for (let i = 0; i < $this.dataSource.length; i++) {
    $this.dataSource[i].body_1755738876240_kVrDg = parseFloat((parseFloat($this.dataSource[i].body_1755738786689_Sawbk / 100) * parseFloat($this.formModel.money_1755739049955_HnGHB)).toFixed(2));
    $this.dataSource[i].body_1756890726483_ZVNw0 =parseFloat( $this.dataSource[i].body_1755738876240_kVrDg.toFixed(2))
}

for (let i = 0; i < $this.dataSource.length; i++) {
    $this.dataSource[i].body_1756890726483_ZVNw0 =parseFloat( $this.dataSource[i].body_1755738876240_kVrDg.toFixed(2))
}

var arr = $this.model['table_1755739234177_VGgw6'];
for(let i = 0; i<arr.length; i++){
     arr[i].body_1755741064871_8zdXz = parseFloat (arr[i].body_1756890890163_hsAxa)
}

for (let i = 0; i < $this.dataSource.length; i++) {
    // 未收款金额 = 本次收款金额
    $this.dataSource[i].body_1755741064871_8zdXz =parseFloat( $this.dataSource[i].body_1756969162868_fE8v8.toFixed(2))
}

var arr = $this.model['table_1755739234177_VGgw6'];
for(let i = 0; i<arr.length; i++){
   arr[i].body_1755741064871_8zdXz = arr[i].body_1756969162868_fE8v8
}

console.log("success1");
for (let i = 0; i < $this.dataSource.length; i++) {
    console.log($this.dataSource[i].body_1755741064871_8zdXz.toFixed(2));
    //本次收款金额 = 未收款金额
    $this.dataSource[i].body_1756891004059_03oFc = parseFloat( $this.dataSource[i].body_1755741064871_8zdXz.toFixed(2))
}

$this.model.select_1754021263360_8lgYi = "2e66c80b5a1c45aab292dbf8a5a5d433";